﻿@inject IDataCacheService _dataCacheService

<MMenu OffsetY>
    <ActivatorContent>
        <MButton Color="@Color" @attributes="@context.Attrs" Dark Text="TextStyle" Rounded="Rounded" Class="@Class">
            @if (string.IsNullOrWhiteSpace(Icon) == false)
            {
                <MIcon Left>@Icon</MIcon>
            }
            @Text
        </MButton>
    </ActivatorContent>

    <ChildContent>
        <div class="bg-theme">
            @ChildContent
        </div>

    </ChildContent>
</MMenu>

@code {
    [Parameter]
    public string Icon { get; set; }

    [Parameter]
    public bool TextStyle { get; set; }

    [Parameter]
    public bool Rounded { get; set; }

    [Parameter]
    public string Text { get; set; }

    [Parameter]
    public string Class { get; set; }

    [Parameter]
    public string Color { get; set; } = "primary";

    [Parameter]
    public RenderFragment ChildContent { get; set; }

}
